home *** CD-ROM | disk | FTP | other *** search
- Path: oasis.rad.upenn.edu!daniels
- From: daniels@oasis.rad.upenn.edu (Jamie Daniels)
- Newsgroups: comp.lang.c++
- Subject: passing arguments to main()
- Date: 1 Mar 1996 16:35:04 GMT
- Organization: University of Pennsylvania
- Message-ID: <4h78vo$nqq@netnews.upenn.edu>
- NNTP-Posting-Host: oasis.rad.upenn.edu
- X-Newsreader: TIN [version 1.2 PL2-upenn1.1]
-
- Hello,
-
- I have a question about c I am not very good with programming. I have this
- project that I want to take two strings one a name the other being an 80
- character message(sentence). I want it to spit out a simplt print statement at
- an Unix prompt. But I don't know how to pass arguments to main(). also I can't
- get the output to be entered in at the unix prompt. I want the output to be a
- command. for a simple example
-
- printf("ping 165.234.323.222");
-
- will not ping this address it only prints this statement before the prompt
-
- any help would be greatly appreciated
- --
- Jamie
-